package com.itheima.stock.mapper;

import com.github.pagehelper.Page;
import com.itheima.stock.entity.StockRtInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

/**
 * @author zby
 * @description 针对表【stock_rt_info(个股详情信息表)】的数据库操作Mapper
 * @created 2024-06-17 20:58:15
 * 对应实体类 {@link StockRtInfo}
 */
@Mapper
public interface StockRtInfoMapper {

    List<StockRtInfo> increase(LocalDateTime currentTime);

    Page<StockRtInfo> stockAll();


    List<StockRtInfo> selectAllByDay(@Param("curTime") LocalDateTime curTime,@Param("openTime") LocalDateTime openTime);


    List<StockRtInfo> selectAllByLastTime(LocalDateTime avlDateTime);

    List<StockRtInfo> selectByCode(@Param("code") String code, @Param("openTime") LocalDateTime openTime, @Param("closeTime") LocalDateTime closeTime);

    int insertBatch(@Param("infos") List<StockRtInfo> infos);
}




